<?php /*a:2:{s:55:"D:\phpstudy_pro\yifei\muban\view\admin\en\nav\list.html";i:1755078063;s:48:"D:\phpstudy_pro\yifei\muban\view\admin\head.html";i:1755076919;}*/ ?>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
    <title>文档管理</title>
    <link rel="stylesheet" type="text/css" href="/static/admin/css/base.css">
<link rel="stylesheet" href="/static/admin/css/font.css">
<link rel="stylesheet" href="/static/admin/css/css.css">
<link rel="stylesheet" href="/static/admin/css/xadmin.css">
<script src="/static/admin/js/jquery.min.js"></script>
<script type="text/javascript" src="/static/admin/lib/layui/layui.js" charset="utf-8"></script>
<script type="text/javascript" src="/static/admin/js/xadmin.js"></script>
<script type="text/javascript" src="/static/admin/js/fl.js"></script>
<script src="/static/admin/js/falan.js"></script>
<script>var lang = "<?php echo htmlentities((string) $lang); ?>"</script>
    <style>
        .son td{
            padding-left: 25px;
        }
        .son-son td{
            padding-left: 50px;
        }
    </style>
</head>
<body leftmargin="8" topmargin="8" background='/static/images/allbg.gif'>
<div class="x-nav">
        <span class="layui-breadcrumb">
          <a href="">Index</a>
          <a href="">Demonstrate</a>
          <a>
            <cite>Navigation</cite></a>
        </span>
    <a class="layui-btn layui-btn-primary layui-btn-small" style="line-height:1.6em;margin-top:3px;float:right" href="javascript:location.replace(location.href);" title="刷新">
        <i class="layui-icon" style="line-height:38px">ဂ</i></a>
</div>
<div class="x-body">
    <div class="layui-row">
        <form class="layui-form layui-col-md12 x-so">
        </form>
    </div>
    <xblock>
        <button class="layui-btn" onclick="x_admin_show('Add导航','/admin/nav/info?id=0&lang=<?php echo htmlentities((string) $lang); ?>')">
            <i class="layui-icon"></i>Add
        </button>
    </xblock>
    <table class="layui-table">
        <thead>
        <tr>
            <th>Nav Title</th>
            <th>Links</th>
            <th>Type</th>
            <th>List template</th>
            <th>Details template</th>
            <th>Show</th>
            <th>Option</th>
        </tr>
        </thead>
        <tbody>
        <?php if(is_array($list) || $list instanceof \think\Collection || $list instanceof \think\Paginator): $i = 0; $__LIST__ = $list;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$value): $mod = ($i % 2 );++$i;?>
        <tr>
            <td><?php echo htmlentities((string) $value['name']); ?>(<?php echo htmlentities((string) $value['son_count']); ?>)</td>
            <td><?php echo htmlentities((string) $value['url']); ?></td>
            <td><?php echo htmlentities((string) $value['web_type_text']); ?></td>
            <td><?php echo htmlentities((string) $value['list_template']); ?></td>
            <td><?php echo htmlentities((string) $value['info_template']); ?></td>
            <td><?php echo htmlentities((string) $value['isshow_text']); ?></td>
            <td class="td-manage">
                <a title="Save"  onclick="x_admin_show('编辑','/admin/nav/info?id=<?php echo htmlentities((string) $value['id']); ?>&lang=<?php echo htmlentities((string) $lang); ?>')" href="javascript:;">
                   Save
                </a>
                <a href="/index?path=<?php echo htmlentities((string) $value['url']); ?>" target="_blank">
                    查看
                </a>
                <a title="Delete" onclick="member_del(this,'<?php echo htmlentities((string) $value['id']); ?>')" href="javascript:;">
                    Delete
                </a>
            </td>
        </tr>
        <?php if(is_array($value['son']) || $value['son'] instanceof \think\Collection || $value['son'] instanceof \think\Paginator): $i = 0; $__LIST__ = $value['son'];if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$item): $mod = ($i % 2 );++$i;?>
        <tr class="son">
            <td><?php echo htmlentities((string) $item['name']); ?>(<?php echo htmlentities((string) $item['son_count']); ?>)</td>
            <td><?php echo htmlentities((string) $item['url']); ?></td>
            <td><?php echo htmlentities((string) $item['web_type_text']); ?></td>
            <td><?php echo htmlentities((string) $item['list_template']); ?></td>
            <td><?php echo htmlentities((string) $item['info_template']); ?></td>
            <td><?php echo htmlentities((string) $item['isshow_text']); ?></td>
            <td class="td-manage">
                <a title="Save"  onclick="x_admin_show('编辑','/admin/nav/info?id=<?php echo htmlentities((string) $item['id']); ?>&lang=<?php echo htmlentities((string) $lang); ?>')" href="javascript:;">
                    Save
                </a>
                <a href="/index?path=<?php echo htmlentities((string) $item['url']); ?>" target="_blank">
                    查看
                </a>
                <a title="Delete" onclick="member_del(this,'<?php echo htmlentities((string) $item['id']); ?>')" href="javascript:;">
                    Delete
                </a>
            </td>
        </tr>
        <?php if(is_array($item['son']) || $item['son'] instanceof \think\Collection || $item['son'] instanceof \think\Paginator): $i = 0; $__LIST__ = $item['son'];if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$message): $mod = ($i % 2 );++$i;?>
        <tr class="son">
            <td><?php echo htmlentities((string) $message['name']); ?></td>
            <td><?php echo htmlentities((string) $message['url']); ?></td>
            <td><?php echo htmlentities((string) $message['web_type_text']); ?></td>
            <td><?php echo htmlentities((string) $message['list_template']); ?></td>
            <td><?php echo htmlentities((string) $message['info_template']); ?></td>
            <td><?php echo htmlentities((string) $message['isshow_text']); ?></td>
            <td class="td-manage">
                <a title="Save"  onclick="x_admin_show('编辑','/admin/nav/info?id=<?php echo htmlentities((string) $message['id']); ?>&lang=<?php echo htmlentities((string) $lang); ?>')" href="javascript:;">
                    Save
                </a>
                <a href="/index?path=<?php echo htmlentities((string) $message['url']); ?>" target="_blank">
                    查看
                </a>
                <a title="Delete" onclick="member_del(this,'<?php echo htmlentities((string) $message['id']); ?>')" href="javascript:;">
                    Delete
                </a>
            </td>
        </tr>
        <?php endforeach; endif; else: echo "" ;endif; ?>
        <?php endforeach; endif; else: echo "" ;endif; ?>
        <?php endforeach; endif; else: echo "" ;endif; ?>
        </tbody>
    </table>
</div>
<script>
    /*Delete*/
    function member_del(obj,id){
        layer.confirm('Confirm要Delete吗？',function(index){
            //发异步Delete数据
            $(obj).parents("tr").remove();
            post('/sys/nav/delete?id=' + id,{},'message');
            layer.msg('已Delete!',{icon:1,time:1000});
        });
    }
    function message(){
        location.reload();
    }
</script>
</body>
</html>